  let search_enter_fn1 = () => {
      e = e || 1;
      type = type || "";
      this.$store.commit("search_page", e);
      type = type || "";
      this.axios({
              methods: "get",
              url: "/search",
              params: {
                  keywords: this.$store.state.search_value,
                  type: type,
                  limit: this.$store.state.search_limit,
                  offset: (e - 1) * this.$store.state.search_limit,
              },
          })
          .then((res) => {
              console.log(res);
              res.data.result.songs.forEach((v) => {
                  v.duration = hsm(v.duration);
                  v.name = bright_search_value(v.name);
                  v.album.name = bright_search_value(v.album.name);
                  v.artists[0].name = bright_search_value(v.artists[0].name);
              });
              this.$nextTick(this.$store.commit("search_data", res.data.result));
          })
          .catch((err) => {
              console.log(err);
          });
  }

  let bright_search_value1 = (val) => {
      let keyword = this.$store.state.search_value;
      console.log(keyword);
      if (val.indexOf(keyword) !== -1) {
          return val.replace(keyword, `<font color='#33ccff'> ${keyword}</font>`);
      } else {
          return val;
      }
  }

  export {
      search_enter_fn1,
      bright_search_value1
  }